const empModule = {
    namespaced: true,
    state() {
        return {
            realName: '李大宝'
        }
    },
    getters: {
        empMsg() {
            return "我爱你中国，亲爱的母亲"
        },
        empSlogan(state, getters, rootState) {
            return rootState.slogan;
        }
    },
    mutations: {
        updateRealName(state, payload) {
            state.realName = payload.realName;
        }
    },
    actions: {
        updateName({commit}, payload) {
            commit({
                type: 'updateRealName',
                realName: payload.realName
            });
        }
    }
}
export default empModule